package com.quanyan.stadiumScheduler.utils;

/**
 * Created by wanglei on 2016/6/12.
 */
public class StringUtils {

    public static boolean isEmpty(String param) {

        return param == null || param.equals("");

    }

    public static boolean isEmpty(String... params) {

        for (String param : params) {
            if (param == null || param.trim().equals("")) {
                return true;
            }
        }

        return false;
    }

    public static boolean isNotEmpty(String param) {
        return !isEmpty(param);
    }

    public static boolean isNotEmpty(String... params) {

        for (String param : params) {
            if (param == null || param.trim().equals("")) {
                return false;
            }
        }

        return true;
    }

    public static String stringNullChange(String param) {
        return isEmpty(param) ? "" : param;
    }

}
